\(\int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx\) [564]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 22, antiderivative size = 53 \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=-\frac {A \sqrt {a+b x^2}}{3 a x^3}+\frac {(2 A b-3 a B) \sqrt {a+b x^2}}{3 a^2 x} \]

[Out]

-1/3*A*(b*x^2+a)^(1/2)/a/x^3+1/3*(2*A*b-3*B*a)*(b*x^2+a)^(1/2)/a^2/x

Rubi [A] (verified)

Time = 0.02 (sec) , antiderivative size = 53, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {464, 270} \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=\frac {\sqrt {a+b x^2} (2 A b-3 a B)}{3 a^2 x}-\frac {A \sqrt {a+b x^2}}{3 a x^3} \]

[In]

Int[(A + B*x^2)/(x^4*Sqrt[a + b*x^2]),x]

[Out]

-1/3*(A*Sqrt[a + b*x^2])/(a*x^3) + ((2*A*b - 3*a*B)*Sqrt[a + b*x^2])/(3*a^2*x)

Rule 270

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[(c*x)^(m + 1)*((a + b*x^n)^(p + 1)/(a*
c*(m + 1))), x] /; FreeQ[{a, b, c, m, n, p}, x] && EqQ[(m + 1)/n + p + 1, 0] && NeQ[m, -1]

Rule 464

Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Simp[c*(e*x)^(m +
 1)*((a + b*x^n)^(p + 1)/(a*e*(m + 1))), x] + Dist[(a*d*(m + 1) - b*c*(m + n*(p + 1) + 1))/(a*e^n*(m + 1)), In
t[(e*x)^(m + n)*(a + b*x^n)^p, x], x] /; FreeQ[{a, b, c, d, e, p}, x] && NeQ[b*c - a*d, 0] && (IntegerQ[n] ||
GtQ[e, 0]) && ((GtQ[n, 0] && LtQ[m, -1]) || (LtQ[n, 0] && GtQ[m + n, -1])) &&  !ILtQ[p, -1]

Rubi steps \begin{align*} \text {integral}& = -\frac {A \sqrt {a+b x^2}}{3 a x^3}-\frac {(2 A b-3 a B) \int \frac {1}{x^2 \sqrt {a+b x^2}} \, dx}{3 a} \\ & = -\frac {A \sqrt {a+b x^2}}{3 a x^3}+\frac {(2 A b-3 a B) \sqrt {a+b x^2}}{3 a^2 x} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.07 (sec) , antiderivative size = 40, normalized size of antiderivative = 0.75 \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=\frac {\sqrt {a+b x^2} \left (-a A+2 A b x^2-3 a B x^2\right )}{3 a^2 x^3} \]

[In]

Integrate[(A + B*x^2)/(x^4*Sqrt[a + b*x^2]),x]

[Out]

(Sqrt[a + b*x^2]*(-(a*A) + 2*A*b*x^2 - 3*a*B*x^2))/(3*a^2*x^3)

Maple [A] (verified)

Time = 2.87 (sec) , antiderivative size = 36, normalized size of antiderivative = 0.68

method result size
gosper \(-\frac {\sqrt {b \,x^{2}+a}\, \left (-2 A b \,x^{2}+3 B a \,x^{2}+A a \right )}{3 a^{2} x^{3}}\) \(36\)
trager \(-\frac {\sqrt {b \,x^{2}+a}\, \left (-2 A b \,x^{2}+3 B a \,x^{2}+A a \right )}{3 a^{2} x^{3}}\) \(36\)
risch \(-\frac {\sqrt {b \,x^{2}+a}\, \left (-2 A b \,x^{2}+3 B a \,x^{2}+A a \right )}{3 a^{2} x^{3}}\) \(36\)
pseudoelliptic \(-\frac {\left (\left (3 x^{2} B +A \right ) a -2 A b \,x^{2}\right ) \sqrt {b \,x^{2}+a}}{3 a^{2} x^{3}}\) \(36\)
default \(A \left (-\frac {\sqrt {b \,x^{2}+a}}{3 a \,x^{3}}+\frac {2 b \sqrt {b \,x^{2}+a}}{3 a^{2} x}\right )-\frac {B \sqrt {b \,x^{2}+a}}{a x}\) \(58\)

[In]

int((B*x^2+A)/x^4/(b*x^2+a)^(1/2),x,method=_RETURNVERBOSE)

[Out]

-1/3*(b*x^2+a)^(1/2)*(-2*A*b*x^2+3*B*a*x^2+A*a)/a^2/x^3

Fricas [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 34, normalized size of antiderivative = 0.64 \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=-\frac {{\left ({\left (3 \, B a - 2 \, A b\right )} x^{2} + A a\right )} \sqrt {b x^{2} + a}}{3 \, a^{2} x^{3}} \]

[In]

integrate((B*x^2+A)/x^4/(b*x^2+a)^(1/2),x, algorithm="fricas")

[Out]

-1/3*((3*B*a - 2*A*b)*x^2 + A*a)*sqrt(b*x^2 + a)/(a^2*x^3)

Sympy [A] (verification not implemented)

Time = 0.88 (sec) , antiderivative size = 70, normalized size of antiderivative = 1.32 \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=- \frac {A \sqrt {b} \sqrt {\frac {a}{b x^{2}} + 1}}{3 a x^{2}} + \frac {2 A b^{\frac {3}{2}} \sqrt {\frac {a}{b x^{2}} + 1}}{3 a^{2}} - \frac {B \sqrt {b} \sqrt {\frac {a}{b x^{2}} + 1}}{a} \]

[In]

integrate((B*x**2+A)/x**4/(b*x**2+a)**(1/2),x)

[Out]

-A*sqrt(b)*sqrt(a/(b*x**2) + 1)/(3*a*x**2) + 2*A*b**(3/2)*sqrt(a/(b*x**2) + 1)/(3*a**2) - B*sqrt(b)*sqrt(a/(b*
x**2) + 1)/a

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 56, normalized size of antiderivative = 1.06 \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=-\frac {\sqrt {b x^{2} + a} B}{a x} + \frac {2 \, \sqrt {b x^{2} + a} A b}{3 \, a^{2} x} - \frac {\sqrt {b x^{2} + a} A}{3 \, a x^{3}} \]

[In]

integrate((B*x^2+A)/x^4/(b*x^2+a)^(1/2),x, algorithm="maxima")

[Out]

-sqrt(b*x^2 + a)*B/(a*x) + 2/3*sqrt(b*x^2 + a)*A*b/(a^2*x) - 1/3*sqrt(b*x^2 + a)*A/(a*x^3)

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 120 vs. \(2 (45) = 90\).

Time = 0.32 (sec) , antiderivative size = 120, normalized size of antiderivative = 2.26 \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=\frac {2 \, {\left (3 \, {\left (\sqrt {b} x - \sqrt {b x^{2} + a}\right )}^{4} B \sqrt {b} - 6 \, {\left (\sqrt {b} x - \sqrt {b x^{2} + a}\right )}^{2} B a \sqrt {b} + 6 \, {\left (\sqrt {b} x - \sqrt {b x^{2} + a}\right )}^{2} A b^{\frac {3}{2}} + 3 \, B a^{2} \sqrt {b} - 2 \, A a b^{\frac {3}{2}}\right )}}{3 \, {\left ({\left (\sqrt {b} x - \sqrt {b x^{2} + a}\right )}^{2} - a\right )}^{3}} \]

[In]

integrate((B*x^2+A)/x^4/(b*x^2+a)^(1/2),x, algorithm="giac")

[Out]

2/3*(3*(sqrt(b)*x - sqrt(b*x^2 + a))^4*B*sqrt(b) - 6*(sqrt(b)*x - sqrt(b*x^2 + a))^2*B*a*sqrt(b) + 6*(sqrt(b)*
x - sqrt(b*x^2 + a))^2*A*b^(3/2) + 3*B*a^2*sqrt(b) - 2*A*a*b^(3/2))/((sqrt(b)*x - sqrt(b*x^2 + a))^2 - a)^3

Mupad [B] (verification not implemented)

Time = 5.20 (sec) , antiderivative size = 35, normalized size of antiderivative = 0.66 \[ \int \frac {A+B x^2}{x^4 \sqrt {a+b x^2}} \, dx=-\frac {\sqrt {b\,x^2+a}\,\left (A\,a-2\,A\,b\,x^2+3\,B\,a\,x^2\right )}{3\,a^2\,x^3} \]

[In]

int((A + B*x^2)/(x^4*(a + b*x^2)^(1/2)),x)

[Out]

-((a + b*x^2)^(1/2)*(A*a - 2*A*b*x^2 + 3*B*a*x^2))/(3*a^2*x^3)